Skip to main content

Markov Chain

Markov Chain theorems are concerned with what will happen in a long run.

A (discrete time, discrete space, time-homogeneous(transition probability will not change whatever time change, that is, not depend on nn)) Markov Chain is specified by the following three ingredients:

  1. A state space SS, any non-empty finite or countbale set
  2. initial probabilities {νi}iS\{\nu_i\}_{i\in S}, where νi\nu_i is the probabiity of starting at state ii at time 0. Thus νi0\nu_i \ge 0 and iνi=1\sum_{i} \nu_i = 1
  3. Transition Probabilities {pij}i,jS\{p_{ij}\}_{i,j\in S}, where pijp_{ij} is the probability of jumping to state ii to state jj. Thus pij0p_{ij} \ge 0 and jpij=1\sum_{j} p_{ij} = 1 for all ii.

We can write markov chain a sequence of random variables X0,X1,X2,X_0, X_1, X_2, \dots where X0X_0 is the initial state and XnX_n is the state at time nn.

  • Initial Probabilities: νi=P(X0=i)iS\nu_i = P(X_0 = i) \forall i \in S
  • the transition probabilities pijp_{ij} are basically conditional probability (conditional on starting). If P(Xn=i>0)P(X_n= i > 0), then P(Xn+1=jXn=i)=pijP(X_{n+1} = j | X_n = i) = p_{ij}. pijp_{ij} does not depend on nn. (again the time-homogeneous property)
  • P(Xn+1=jXn=in,Xn1=in1,,X1=i1,X0=i0)=P(Xn+1=jXn=in)=pinjP(X_{n+1} = j|X_n = i_n, X_{n-1} = i_{n-1}, \dots, X_1 = i_1, X_0 = i_0) = P(X_{n+1} = j|X_n = i_n) = p_{i_nj} for all n0n \ge 0 and j,in,in1,,i1,i0Sj, i_n, i_{n-1}, \dots, i_1, i_0 \in S (Markov Property). The equation basically says that the probability of the next state depends only on the current state, not on the past states. Also states that pij=P(Xn+1=jXn=i)p_{ij} = P(X_{n+1} = j|X_n = i).
  • P(Xn=in,Xn1=in1,,X1=i1,X0=i0)=νi0pi0i1pi1i2pin1inP(X_n = i_n, X_{n-1} = i_{n-1}, \dots, X_1 = i_1, X_0 = i_0) = \nu_{i_0} p_{i_0i_1} p_{i_1i_2} \dots p_{i_{n-1}i_n}
  • Denote μi(n)=P(Xn=i)\mu^{(n)}_i = P(X_n = i), then μi(n)=jμj(n1)pji\mu^{(n)}_i = \sum_{j} \mu^{(n-1)}_j p_{ji} for all n1n \ge 1 and iSi \in S. μi(n)\mu^{(n)}_i present the end of nth steps with state i. (e.g. P(X1=1)=μ1(1)=jνjpj1P(X_1 = 1) = \mu^{(1)}_1 = \sum_{j} \nu_j p_{j1})
    • μ(n)=νPn=μ(0)Pn\mu^{(n)} = \nu P^n = \mu^{(0)} P^n
  • pij(n)=P(Xn=jX0=i)=P(Xm+n=jXm=i)=Pi(Xn=j)p_{ij}^{(n)} = P(X_n = j|X_0 = i) = P(X_{m+n}=j|X_m = i) = P_i(X_n = j)
    • e.g. pii(2)=kpikpkip_{ii}^{(2)} = \sum_k p_{ik}p_{ki} then we have pii(n)=kpik(n1)pkip_{ii}^{(n)} = \sum_k p_{ik}^{(n-1)}p_{ki} similarly pij(n)=kpik(n1)pkjp_{ij}^{(n)} = \sum_k p_{ik}^{(n-1)}p_{kj}
    • Pi()=P(X0=i)P_i(\cdots) = P(\cdots|X_0 = i)
    • Ei()=E(X0=i)E_i(\cdots) = E(\cdots|X_0 = i)
    • pij(n)p_{ij}^{(n)} basically means the probability of being at state jj after nn steps, given that you start at state ii.

The best way to get such pij(n)p_{ij}^{(n)} is to calculate by P(n)P^{(n)} where PP is the transition matrix.

CHAPMAN-KOLMOGOROV EQUATION: pij(n+m)=kpik(n)pkj(m)p_{ij}^{(n+m)} = \sum_k p_{ik}^{(n)}p_{kj}^{(m)}

CHAPMAN-KOLMOGOROV INEQUALITY: pij(m+n)pik(n)pkj(m)p_{ij}^{(m + n)} \le p_{ik}^{(n)}p_{kj}^{(m)}

Markov Chain Property

A state ii is called recurrent if Pi(Xn=i for infinitely many n)=1P_i(X_n = i \text{ for infinitely many }n) = 1 (or equivalently n=1pii(n)=\sum_{n = 1}^{\infty} p_{ii}^{(n)} = \infty). A state ii is called transient if Pi(Xn=i for infinitely many n)=0P_i(X_n = i \text{ for infinitely many }n) = 0 (or equivalently n=1pii(n)<\sum_{n = 1}^{\infty} p_{ii}^{(n)} < \infty). More easily, a state ii is recurrent if fii=1f_{ii} = 1 for all n1n \ge 1, otherwise transient.

Let N(i)N(i) be a random variable that present the total number of times the chain hits ii (not counting time 0).

  • let fijf_{ij} present return probability from state ii to jj, then fij=Pi(N(j)1)f_{ij} = P_i(N(j) \ge 1) and fijfjj(n1)=Pi(N(j)n)f_{ij}f_{jj}^{(n - 1)} = P_i(N(j) \ge n)
  • The complementary probability 1fij=Pi(Xnjn1)1 - f_{ij} = P_i(X_n \ne j \forall n \ge 1)
  • Pi(chain will eventually visit j and then eventually visit k)=fijfjkP_i(\text{chain will eventually visit }j \text{ and then eventually visit } k) = f_{ij}f_{jk}

f - expansion: fij=pij+kjpikfkjf_{ij} = p_{ij} + \sum_{k\ne j} p_{ik}f_{kj}

Communicating States:

  • State ii communicates with state jj, written iji\to j , if fij>0f_{ij} > 0, i.e., if it is possible to get from ii to jj.
  • Let fij>0    m1f_{ij} > 0 \iff \exists m\ge 1 with pij(m)>0p_{ij}^{(m)} > 0, i.e., there is some time mm for which it is possible to get from ii to jj in mm steps.
  • We will write iji \leftrightarrow j if iji \to j and jij \to i.

A Markov Chain is irreducible if ij,i,jSi \to j, \forall i,j \in S, i.e., if fij>0,i,jSf_{ij} > 0, \forall i,j \in S. Otherwise, it is reducible.

If iki\to k and ljl\to j, and n=1pkl(n)=\sum_{n=1}^{\infty} p_{kl}^{(n)} = \infty, then n=1pij(n)=\sum_{n=1}^{\infty} p_{ij}^{(n)} = \infty.

If iki\leftrightarrow k, then ii is recurrent iff kk is recurrent.

Stationary Distribution: If π\pi is a probability distribution on SS, i.e., iS,πi0\forall i \in S, \pi_i \ge 0 ans iSπi=1\sum_{i \in S} \pi_i = 1, then π\pi is a stationary distribution for a Markov Chain with transition probabilities pijp_{ij} if πi=jSπjpji\pi_i = \sum_{j \in S} \pi_j p_{ji}. In matrix form, π=πP\pi = \pi P.

  • A markov chain with stationary distribution π\pi. If such chain start with probabilities πi\pi_i, then it will keep the same probabilities one time uint later
  • π\pi also is a eigenvector with eigenvalue λ=1\lambda = 1
  • if μ(0)=ν=π\mu^{(0)} = \nu = \pi, then μ(1)=π\mu^{(1)} = \pi and μ(n)=π\mu^{(n)} = \pi for all n1n \ge 1.

S<,i,jS,iSpij=1,jSpij=1    |S| < \infty, \forall i,j \in S, \sum_{i\in S}p_{ij} = 1, \sum_{j\in S}p_{ij} = 1 \implies such markov chain is doubly stochastic.

A Markov Chain is reversible or time reversible with respect to probability distribution π\pi, if i,jS,πipij=πjpji\forall i,j \in S, \pi_ip_{ij} = \pi_jp_{ji}.

  • use to understand whether stationary distribution exists.
  • A chain is reversible with respect to π    π\pi\implies \pi is a stationary distribution. (converse is not true)
    • e.g. p12=p21=p31=1p_{12} = p_{21} = p_{31} = 1, π=(1/3,1/3,1/3)\pi = (1/3, 1/3, 1/3). Then we have π1p13π3p31\pi_{1} p_{13} \ne \pi_{3} p_{31}, so it is not reversible.

Markov Chain with transitions pijp_{ij} on a state space SS, and a state iSi\in S, the period of ii is the greatest common divisor of the set {i:n1,pii(n)=P(Xn=iX0=i)}\{i: \forall n\ge 1, p_{ii}^{(n)} = P(X_n = i| X_0 = i)\}.

  • A chain is aperiodic if the period of every state is 1.

THEOREM: Suppose a Markov chain is irreducible and aperiodic and has a stationary distribution {π}\{\pi\}. Then regardless of the initial distribution μi\mu_i, we have iS,limnP(Xn=i)=πi\forall i \in S, \lim_{n\to\infty} P(X_n = i) = \pi_i.